package org.siqisource.webstart.tools.proxy;

import java.io.IOException;

import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.FillLayout;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.widgets.Shell;

/**
 * Hello world!
 * 
 */
public class App {

	public static void main(String[] args) throws IOException, InterruptedException {
		final App app = new App();
		app.run();
	}

	public void run() {
		final Display display = new Display();
		final Shell shell = new Shell(display);
		FillLayout layout = new FillLayout();
		shell.setLayout(layout);
		shell.setText("extractApache");
		Label lable = new Label(shell,SWT.WRAP);
		lable.setText("An configed Apache proxy has extract to "
				+ApacheStart.APACHE_HOME
				+",run "+ApacheStart.APACHE_HTTPD
				+",before develop on webstart.");
		
		ApacheStart.prepare();
		shell.open();
		
		while (!shell.isDisposed()) {
			if (!display.readAndDispatch())
				display.sleep();
		}
		display.dispose();
	}

}
